package org.example.flea_market_mvc.enums;

/**
 * 商品状态枚举类
 * 定义商品在系统中的不同状态码和描述
 */
public enum ProductStatusEnum {
    ON_SALE(1, "上架"),
    OFF_SALE(2, "下架"),
    UNDER_REVIEW(3, "审核中"),
    EXPIRED(4, "已过期"),
    DELETED(5, "已删除");

    private final int code;      // 状态代码
    private final String description;  // 状态描述

    ProductStatusEnum(int code, String description) {
        this.code = code;
        this.description = description;
    }

    public int getCode() {
        return code;
    }

    public String getDescription() {
        return description;
    }
}